<?php

/**
 * BeamrSlide form.
 *
 * @package    form
 * @subpackage BeamrSlide
 * @version    SVN: $Id: sfDoctrineFormTemplate.php 6174 2007-11-27 06:22:40Z fabien $
 */
class BeamrSlideForm extends BaseBeamrSlideForm
{
  public function configure()
  {
    $this->widgetSchema['presentation_id']  = new sfWidgetFormInputHidden();
    $this->widgetSchema['weight']           = new sfWidgetFormInputHidden();

    $this->widgetSchema['content']->setAttribute('rows', 10);
    $this->widgetSchema['content']->setAttribute('cols', 79);

    if ($this->getObject()->isNew()) {
      unset($this['presentation_id']);
      $this->widgetSchema['weight']->setAttributes(array('value' => 9999));
    }

    unset($this['thumbnail'], $this['token'], $this['created_at'], $this['updated_at']);
  }
}